package com.sharp.authorization.holder;

import com.sharp.authorization.bo.user.UserInfo;

/**
 * Title: UserInfoHolder
 * Description: Copyright: Copyright (c) 2019 Company: BHFAE
 *
 * @author Sharp
 * @date 2021/8/25 17:41
 */
public class UserInfoHolder {

    private static final ThreadLocal<UserInfo> USER_INFO_HOLDER = new ThreadLocal<>();

    private UserInfoHolder() {
    }

    public static void set(UserInfo s) {
        USER_INFO_HOLDER.set(s);
    }

    public static UserInfo get() {
        return USER_INFO_HOLDER.get();
    }
}
